//
//  ViewController.m
//  ios11-3
//
//  Created by mac on 15-11-3.
//  Copyright (c) 2015年 yb. All rights reserved.
//

#import "ViewController.h"
#import <QuartzCore/QuartzCore.h>

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad
{
    [super viewDidLoad];
	// Do any additional setup after loading the view, typically from a nib.
    //UIView * block = [[UIView alloc] initWithFrame:CGRectMake(100, 300, 100, 100)];
    
    self.view.backgroundColor = [UIColor redColor];
    //UILabel * l = [[UILabel alloc] initWithFrame:CGRectMake(50, 200, 100, 44)];
    //l.text = @"你好，世界";
    //l.textColor = [UIColor blackColor];
    //[self.view addSubview:l];
    
//    for (int i=0; i<5; i++) {
//        CGFloat stepper = 20;
//        UIView * view = [[UIView alloc] initWithFrame:CGRectMake(20+ i*stepper, 60 +i *stepper, 200 - 2*i*stepper, 200-2*i*stepper)];
//        view.backgroundColor = [UIColor whiteColor];
//        view.layer.borderWidth = 1;
//        [self.view addSubview:view];
//    }
    
    UIView * v = [[UIView alloc] initWithFrame:CGRectMake(20, 200, 200, 200)];
    v.layer.borderWidth = 2;
    [self.view addSubview:v];
    
    UIView * line2 = [[UIView alloc] initWithFrame:CGRectMake(0, 99, 200, 2)];
    line2.backgroundColor = [UIColor blackColor];
    [v addSubview:line2];
    
    UIView * line3 = [[UIView alloc] initWithFrame:CGRectMake(99, 0, 2, 200)];
    line3.backgroundColor = [UIColor blackColor];
    [v addSubview:line3];
    
    UIView * yuan = [[UIView alloc] initWithFrame:CGRectMake(100, 0, 200, 200)];
    yuan.layer.cornerRadius = 100;
    yuan.layer.borderWidth = 2;
    [v addSubview:yuan];
    
}

- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
